<?php
class Test {
	public static function runAll() {
		// Database
		self::databaseCodesInsert();
		
		// Codemanager
		self::codemanager();
		
		echo date('l jS \of F Y h:i:s A');
		echo BR;
		// Image
		$ppp = "c:/Documents and Settings/stepan/Data/foto/libanky/private/tmp";
		$originalImg = new Img("$ppp/P7120022_navysku.JPG");
		$originalImgS = new Img("$ppp/P7120061_nasirku.JPG");
		$originalImg->resize(0, 500, "$ppp/P7120022_navysku_0x500.JPG");
		
		$originalImgS->resize(0, 500, "$ppp/P7120061_nasirku_0x500.JPG");
		
		
		
		$originalImg->resizeProportional(2.1, "$ppp/P7120022_navysku_2.1.JPG");
		System::stopMaxExecutionTimeCounting();
		$originalImg->resize(500, 0, "$ppp/P7120022_navysku_500x0.JPG");
		$originalImg->resizeProportional(0.5, "$ppp/P7120022_navysku_0.5.JPG");
		$originalImg->resizeProportional(0.1, "$ppp/P7120022_navysku_0.1.JPG");
		System::continueMaxExecutionTimeCounting();
		$originalImg->resizeProportional(2, "$ppp/P7120022_navysku_2.JPG");
		
		$originalImg->resize(0, 500, "$ppp/P7120022_navysku_0x500.JPG");
		$originalImgS->resize(0, 500, "$ppp/P7120061_nasirku_0x500.JPG");
		$originalImg->resizeProportional(2.1, "$ppp/P7120022_navysku_2.1.JPG");
		$originalImg->resize(500, 0, "$ppp/P7120022_navysku_500x0.JPG");
		$originalImg->resizeProportional(0.5, "$ppp/P7120022_navysku_0.5.JPG");
		$originalImg->resizeProportional(0.1, "$ppp/P7120022_navysku_0.1.JPG");
		$originalImg->resizeProportional(2, "$ppp/P7120022_navysku_2.JPG");
		
		
		echo date('l jS \of F Y h:i:s A');
		
		die;
		
		
		
		// Database
		
		$res = $info->getDBConnector()->query(Constants::DB_QUERY_USERS_ALL);
		
		while($obj = User::mysqlFetch($res)) {
			echo $obj->fullName();
			echo BR;
		}
		$res = $info->getDBConnector()->query(Constants::DB_QUERY_OFFERS_ALL);
		
		while($obj = Offer::mysqlFetch($res)) {
			echo serialize($obj);
			Logger::getLogger()->debug($obj->town);
			Logger::getLogger()->debug($obj->street);
		}
		$mujstr = "Příliš ďábelské ódy úpěl žluťoučký kůň.";
		Logger::getLogger()->debug($mujstr);
		
		
		
		
		
	}
	public static function databaseCodesInsert() {
		$code = new Codes();

		$code->cs = "cestina";
		$code->en = "anglictina";
		$code->shortCut = "shortcut";
		
		$code->insert();
	}
	public static function codemanager() {
		$cm = CodeManager::getCodeManager();
		echo $cm->get("10001");
		echo $cm->get("20001");
		echo $cm->get("30001");
	}
}
?>